-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Try using last tag when -Prelease.tryUsingLastTag=true is provided #171
Conversation
@rpalcolea @chali Could either of you please have a look at this pull request when you find time? |
Hey @kranich, so far I'm hesitant to merge, but I'm not sure I completely understand the use case where you would like to use the feature. Could you provide an example? |
Rather than giving an example, please let me elaborate a bit. I am currently working in a project that has a fairly complex GitLab CI/CD pipeline where every build consists of roughly 60 jobs spread over 10 stages. About a dozen of the jobs depend on the project version determined using the nebula-release-plugin. With every push to GitLab, a development version is built. When we want to build a release or release candidate we locally run The dozen jobs are identical for development and release builds except for the version strategy that is used. We cannot always use We determine how we invoke gradle by setting an environment variable Firstly, the If this PR was merged, we could put Presumably @asoee had a similar use case in mind when filing issue #84. |
@kranich I understand the use case now. Unfortunately, we won't be able to merge the feature. It is very specific to your situation. The core idea of the plugin is to have a clear action leading to a clear output eg: calling I believe |
OK. Thank you for the review and the suggestion of building a wrapper plugin. Maybe then you should close #84 as well. |
Fixes #84.
Suggestions for improvements, e.g. a better name for the flag, are more than welcome.
I have introduced a new flag rather than changing the behaviour of
-Prelease.useLastTag=true
in order to remain backwards compatible.The use case is as follows: Suppose that in a CI pipeline you want to use the last tag when rebuilding this tag and otherwise fallback to the default strategy to determine the project version. Then you can simply add
release.tryUsingLastTag=true
to the gradle.properties file of your project.